<template>
  <div>
    <!-- 合作医生 -->
    <el-card>
      <el-form :model="searchForm" ref="searchRef" inline>
        <el-form-item label="医生账号" prop="doctorUsername">
          <el-input
            v-model="searchForm.doctorUsername"
            placeholder="请输入医生账号"
            class="form_input"
          />
        </el-form-item>
        <el-form-item label="医生昵称" prop="doctorNickname">
          <el-input
            v-model="searchForm.doctorNickname"
            placeholder="请输入医生昵称"
            class="form_input"
          />
        </el-form-item>
      </el-form>
    </el-card>
    <el-card>
      <PagingQuery
        :page="page"
        :size="size"
        :total="total"
        @getList="getList"
        class="mt-2"
      />
    </el-card>
  </div>
</template>

<script setup>
import { ref, onMounted } from "vue";
import { ElMessage, ElMessageBox } from "element-plus";
import PagingQuery from "@/components/PagingQuery.vue";
import { handleApiResponse } from "@/utils/request.js";
import { ListCooperativeDoctorsAll } from "../../../../wailsjs/go/api/DeviceApi";

onMounted(() => {
  getList();
});

const searchRef = ref(null);
const searchForm = ref({
  doctorUsername: "", // 账号
  doctorNickname: "", // 昵称
});

const page = ref(1);
const size = ref(10);
const total = ref(0);
const tableData = ref([]);
async function getList(e) {
//   if (e) {
//     page.value = e.page;
//     size.value = e.size;
//   }
//   handleApiResponse(() => ListCooperativeDoctorsAll({})).then((res) => {
//     if (res.code == 0) {
//       tableData.value = res.data.list || [];
//       total.value = res.data.total || 0;
//     }
//   });
}
</script>

<style scoped lang="scss">
</style>